const router = new require("@koa/router")({prefix:"/notify"});
const { auth } = require("../middleware/auth")
const {
    get_new_friend_notify,
    add_friend_notify,
    update_notify_status
} = require("../controller/notify_controller")

const {
     get_new_friend_notify_validator,
     add_friend_notify_validator,
     update_notify_status_validator
} = require("../validate/notify_validator",)

/**
 * 获取好友或群组申请
 */
router.get("/get_new_friend_notify",auth,get_new_friend_notify_validator,get_new_friend_notify)

/**
 * 添加新朋友申请
 */
router.post("/add_friend_notify",auth,add_friend_notify_validator,add_friend_notify)

/**
 * 修改通知状态 
 */
router.put("/update_notify_status",auth,update_notify_status_validator,update_notify_status)


module.exports = router;